package cn.edu.scau.cmi.suyaoxing.hibernate.domain;

public class Student {
	private long id;
	private String name;
	private Teacher teacher;
	public Student(int id,String name,Teacher teacher) {
		this.id=id;
		this.name=name;
		this.teacher=teacher;
	}
	public Student() {
		
	}
	public void setId(long id) {
		this.id=id;
	}
	public long getId() {
		return this.id;
	}
	public void setName(String name) {
		this.name=name;
	}
	public String getName() {
		return this.name;
	}
	public void setTeacher(Teacher teacher) {
		this.teacher=teacher;
	}
	public Teacher getTeacher() {
		return this.teacher;
	}
	@Override
	public String toString() {
		return "student_id: "+this.id+"  student_name: "+this.name+"  "+this.teacher.toString();
	}

}
